package com.eight.cloud.job.common.constants;

import lombok.Getter;

/**
 * @ClassName: ScheduleConstants
 * @Author: TXC
 * @Date: 2025-02-25 10:37
 **/
public class ScheduleConstants {
    public static final String TASK_CLASS_NAME = "TASK_CLASS_NAME";
    public static final String TASK_PROPERTIES = "TASK_PROPERTIES";
    public static final String[] JOB_WHITELIST_STR = new String[]{"com.eight"};
    public static final String LOOKUP_RMI = "rmi:";
    public static final String LOOKUP_LDAP = "ldap:";
    public static final String LOOKUP_LDAPS = "ldaps:";
    public static final String HTTP = "http://";
    public static final String HTTPS = "https://";
    public static final String[] JOB_ERROR_STR = new String[]{"java.net.URL", "javax.naming.InitialContext", "org.yaml.snakeyaml", "org.springframework", "org.apache"};

    public ScheduleConstants() {
    }

    @Getter
    public static enum ExecutionJobStatus {
        NORMAL(1),
        PAUSE(0);

        private final Integer value;

        ExecutionJobStatus(Integer value) {
            this.value = value;
        }
    }

    @Getter
    public static enum QuartzJobStatus {
        DISABLE(0),
        ENABLE(1);

        private final Integer value;

        QuartzJobStatus(Integer value) {
            this.value = value;
        }
    }
}
